<template>
	<!-- <view :style="'height:'+scrollH+'px;'"> -->
		<view style="margin-bottom:300upx">


		<swiper-image :resdata="swipers"></swiper-image>
		<!-- 首页分类 -->
		<index-navs :resdata="indexnavs"></index-navs>
		<!-- 全局分割线 -->
		<divider></divider>
		<!-- 三图广告位 -->
		<three-adv :resdata="threeAdv"></three-adv>
		<divider></divider>
		<!-- 基础卡片组件 -->
		<card :headTitle="headTitle" :bodyCover="bodyCover"></card>
		<!-- 公共列表组件  750-5=745   745/2=372.5 -->
		<view class="row">
			<view style="width: 372.5upx;">
				<image src="/static/images/demo/demo1.jpg" mode="widthFix" lazy-load=""></image>
				<view class="p-2 pt-1">
					<view class="font-md">
						米家空调
					</view>
					<text class="d-block font text-light-muted">1.5匹变频</text>
					<view class="d-flex my-1">
						<!-- 价格显示 -->
						<price>1369</price>
						<view class="font-sm  line-h text-light-muted line-through ml-1 a-self-end"  >
							￥2699
						</view>
					</view>
				</view>
			</view>
		</view>
		<view style="margin-bottom: 200upx;">
			fcefeq
		</view>
		<view style="margin-bottom: 200upx;">
			fcefeq
		</view>
		<view style="margin-bottom: 200upx;">
			fcefeq
		</view>
	</view>
</template>

<script>
	import swiperImage from '@/components/index/swiper-image.vue'
	import indexNavs from '@/components/index/index-nav.vue'
	import threeAdv from "@/components/index/three-adv.vue"
	import card from "@/components/common/card.vue"
	// 价格
	import price from "@/components/common/price.vue"
	export default {
		components: {
			swiperImage,
			indexNavs,
			threeAdv,
			card,
			price
		},

		data() {
			return {
				scrollH: "500",
				headTitle: "今日推荐",
				bodyCover: "/static/images/demo/demo4.jpg",
				swipers: [{
						src: "../../static/images/demo/demo4.jpg"
					},
					{
						src: "../../static/images/demo/demo4.jpg"
					},
					{
						src: "../../static/images/demo/demo4.jpg"
					},
					{
						src: "../../static/images/demo/demo4.jpg"
					}
				],
				indexnavs: [{
						src: "/static/images/indexnav/1.png",
						text: "新品发布"
					},
					{
						src: "/static/images/indexnav/2.gif",
						text: "小米众筹"
					},
					{
						src: "/static/images/indexnav/3.gif",
						text: "以旧换新"
					},
					{
						src: "/static/images/indexnav/4.gif",
						text: "1分拼团"
					},
					{
						src: "/static/images/indexnav/5.gif",
						text: "超值特卖"
					},
					{
						src: "/static/images/indexnav/6.gif",
						text: "小米秒杀"
					},
					{
						src: "/static/images/indexnav/7.gif",
						text: "真心想要"
					},
					{
						src: "/static/images/indexnav/8.gif",
						text: "电视热卖"
					},
					{
						src: "/static/images/indexnav/9.gif",
						text: "家电热卖"
					},
					{
						src: "/static/images/indexnav/10.gif",
						text: "米粉卡"
					},

				],
				threeAdv: {
					big: {
						src: "/static/images/demo/demo1.jpg"
					},
					smalltop: {
						src: "/static/images/demo/demo2.jpg"
					},
					smallbottom: {
						src: "/static/images/demo/demo2.jpg"
					}
				}
			}

		},
		onLoad() {
			uni.getSystemInfo({
				success: (res) => {
					console.log(res.windowHeight)
					this.scrollH = res.windowHeight;
				}
			});
			console.log("ewrfdew")
		},

		onShow() {
			console.log('onshow')
		},
		methods: {

		}
	}
</script>

<style>

</style>
